package com.guigu.serviceorder.service;

import com.guigu.common_util.pojo.utils.Result;
import com.guigu.serviceorder.entity.TbOrder;
import com.guigu.serviceorder.entity.TbReturnOrder;
import com.baomidou.mybatisplus.extension.service.IService;
import com.guigu.serviceorder.entity.TbReturnOrderItem;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author jobob
 * @since 2020-07-08
 */
public interface ITbReturnOrderService extends IService<TbReturnOrder> {
    // 退货分页条件查询
    Result findPage1(Map<String, Object> searchMap, Integer page, Integer size);
    // 退款分页条件查询
    Result findPage2(Map<String, Object> searchMap, Integer page, Integer size);
    //同意退款
    Result agreeRefund(String id,Integer money,Integer adminId);
    //拒绝退款
    Result rejectRefund(String id,String remark,Integer adminId);
    //同意退货
    Result agreeRefundGoods(String id,Integer adminId);
    //拒绝退货
    Result rejectRefundGoods(String id,String remark,Integer adminId);
    //根据orderid拿到orderitem
    Result findOrderItemByOrderId(String orderId);
    //根据returnorderid拿到returnorderitem
    Result findReturnOrderItemByReturnOrderId(String returnOrderId);
    //删除退货订单
    Result deletereturnOrder(List<TbReturnOrder> returnorders);

}
